import request from '@/utils/request'

export function getEmployeeSimple(){
 return request({
 url:'/sys/user/simple'
 })
}

// 获取员工列表接口
export function getEmployeelist(page,size){
    return request({
    url:'/sys/user',
    method:'get',
    params:{page,size}
    })
   }

// 新增员工列表接口
export function addEmployeelist(data){
    return request({
    url:'/sys/user',
    method:'post',
    data
    })
   }
// 删除接口
export function deleEmployeelist(id){
    return request({
    url:`/sys/user/${id}`,
    method:'delete',
    })
   }
// 批量添加员工
export function addEmployeeBatch(data){
    return request({
    url:'/sys/user/batch',
    method:'post',
    data
    })
   }
 // 修改员工信息
 export function saveUserDetailById(data) {
    return request({
      method: 'put',
      url: `/sys/user/${data.id}`,
      data
    })
  }
  // // 更新角色接口
 export function assignROles(data) {
  return request({
    method: 'put',
    url: '/sys/user/assignRoles',
    data
  })
}

